package com.truyen.model;

import java.util.ArrayList;
import java.util.List;

public class TruyenHintModel {
	private String idComic;
    private String nameComic;
    private String nameUnsignedComic;
    private String linkImage;
    private String nameImage;
	
	/**
	 * @return the idComic
	 */
	public String getIdComic() {
		return idComic;
	}
	/**
	 * @param idComic the idComic to set
	 */
	public void setIdComic(String idComic) {
		this.idComic = idComic;
	}
	/**
	 * @return the nameComic
	 */
	public String getNameComic() {
		return nameComic;
	}
	/**
	 * @param nameComic the nameComic to set
	 */
	public void setNameComic(String nameComic) {
		this.nameComic = nameComic;
	}
	/**
	 * @return the nameUnsignedComic
	 */
	public String getNameUnsignedComic() {
		return nameUnsignedComic;
	}
	/**
	 * @param nameUnsignedComic the nameUnsignedComic to set
	 */
	public void setNameUnsignedComic(String nameUnsignedComic) {
		this.nameUnsignedComic = nameUnsignedComic;
	}
	/**
	 * @return the linkImage
	 */
	public String getLinkImage() {
		return linkImage;
	}
	/**
	 * @param linkImage the linkImage to set
	 */
	public void setLinkImage(String linkImage) {
		this.linkImage = linkImage;
	}
	/**
	 * @return the nameImage
	 */
	public String getNameImage() {
		return nameImage;
	}
	/**
	 * @param nameImage the nameImage to set
	 */
	public void setNameImage(String nameImage) {
		this.nameImage = nameImage;
	}
    
	public static TruyenHintModel addComicHintModel(Object obj) {
		Object[] arr = (Object[]) obj;
		String idComic = (String) arr[0];
		String nameComic = (String) arr[1];
		String nameUnsignedComic = (String) arr[2];
		String linkImage = (String) arr[3];
		String nameImage = (String) arr[4];
		TruyenHintModel chm = new TruyenHintModel();
		chm.setIdComic(idComic);
		chm.setNameComic(nameComic);
		chm.setNameUnsignedComic(nameUnsignedComic.replace(" ", "-"));
		chm.setLinkImage(linkImage);
		chm.setNameImage(nameImage);
		return chm;
	}

	public static List<TruyenHintModel> addLstComicHintModel(List<Object> lstOjb) {
		ArrayList<TruyenHintModel> arr = new ArrayList<TruyenHintModel>();
		for (Object lst : lstOjb) {
			arr.add(addComicHintModel(lst));
		}
		return arr;
	}

}
